﻿#region Usings
using BK.Model;
using BK.Repositories.Abstract;
#endregion

namespace BK.BlusinessLogic
{
    public class BestExpensesFilesBl : IExpensesFilesBl<BestExpense, BestExpensesFile>
    {
        #region Readonly & Static Fields
        private readonly IExpensesFilesRepository<BestExpense, BestExpensesFile> _bestExpensesFilesRepository;
        #endregion

        #region C'tors
        public BestExpensesFilesBl(IExpensesFilesRepository<BestExpense, BestExpensesFile> bestExpensesFilesRepository)
        {
            _bestExpensesFilesRepository = bestExpensesFilesRepository;
        }
        #endregion

        #region IExpensesFilesBl<BestExpense,BestExpensesFile> Members
        public ImportedFile GetAnotherByExpense(BestExpense bestExpense)
        {
            return _bestExpensesFilesRepository.GetAnotherByExpense(bestExpense);
        }

        public void AddExpense(BestExpensesFile expensesFile, BestExpense expense)
        {
            expensesFile.Expenses.Add(expense);
        }
        #endregion
    }
}